package com.fa4j.product.item.model;

import com.fa4j.common.base.model.PageQuery;
import com.fa4j.common.data.annotation.Query;
import com.fa4j.common.data.model.QueryType;
import io.swagger.v3.oas.annotations.media.Schema;
import jakarta.validation.constraints.Size;
import lombok.Data;

@Data
@Schema(description = "商品信息分页查询参数")
public class ItemPageQuery extends PageQuery {

    @Query(type = QueryType.LIKE)
    @Size(max = 32)
    @Schema(description = "商品标题")
    private String title;

    @Query(type = QueryType.LIKE)
    @Size(max = 64)
    @Schema(description = "商品描述")
    private String description;

    @Schema(description = "商品分类")
    private Integer categoryId;

    @Schema(description = "商品类型")
    private ItemType type;

    @Schema(description = "商品状态")
    private ItemState state;

    @Size(max = 32)
    @Schema(description = "商品单位")
    private String unit;

}
